﻿Imports Runa.Resources.ResourceManager
Imports Microsoft.Xna.Framework
Imports MonoGame.Framework
Imports Runa.Core.GamePackage

' The Blank Page item template is documented at http://go.microsoft.com/fwlink/?LinkId=234238

''' <summary>
''' An empty page that can be used on its own or navigated to within a Frame.
''' </summary>
Public NotInheritable Class GameViewPage
    Inherits Page

    Private Property Game() As GameRender

    Public Sub New()
        ' This call is required by the designer.
        InitializeComponent()
        ' Add any initialization after the InitializeComponent() call.
        GameRender.GamePackage = CType(g_gamePkg, GamePackageBase)
        Dim launchArguments As String = ""
        Me.Game = XamlGame(Of GameRender).Create(launchArguments, Window.Current.CoreWindow, Me.DXSwapChainPanel)
    End Sub

    ''' <summary>
    ''' Invoked when this page is about to be displayed in a Frame.
    ''' </summary>
    ''' <param name="e">Event data that describes how this page was reached.  The Parameter
    ''' property is typically used to configure the page.</param>
    Protected Overrides Sub OnNavigatedTo(e As Navigation.NavigationEventArgs)

    End Sub

End Class